def main():
    word_1=list(input())
    word_2=list(input())
    min_len=min(len(word_1),len(word_2))
    prefix_len=0
    print('<',end='')
    for i in range(min_len):   
        if word_1[i]==word_2[i]:
           print(word_1[i],end='')
        else:
            break
    print('>')
main()